﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Streamsol.Crm.XrmDevelopmentToolkit
{
    public class XrmStatusInfo
    {
        public string DisplayName { get; set; }
        public int Value { get; set; }

        public XrmStatusInfo()        { }

        public XrmStatusInfo(string displayName, int value)
        {
            this.DisplayName = displayName;
            this.Value = value;
        }

        public override string ToString()
        {
            return this.DisplayName;
        }

        public static implicit operator int(XrmStatusInfo obj)
        {
            return obj.Value;
        }             
    }
}
